//名称格式化过滤器
const nameSubFilter = function(value){
    // console.log("过滤名称",typeof(value) === 'string');
    if(!(typeof(value) === 'string')) return;
    value = value.length > 15 ? value.slice(0,15) + '......' : value;
    return value;
}

//订单状态过滤器
let orderStateFilter = orderState=> {
    let orderStateStr = '';
    switch(orderState){
        case 0:
            orderStateStr = '未付款';
            break;
        case 1:
            orderStateStr = '已付款';
            break;
    }
    return orderStateStr;
}

export { nameSubFilter,orderStateFilter }